package moreHealthControl;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import moreHealthView.StudentInformationForm;

public class StudentFormRadioButtonListener implements ActionListener
	{	
		
		//ATTRIBUTES ======================================
		

		//label that associates with the entered text field.
		String radioButtonLabelx_="";
		
		//the value entered in the text field.
		String radioButtonValuex_ ="";
		
		
		//INTENT: the label of the text field in which data was entered.
		//PRE-CONDITION : 
			//1. The label name should be relevant to the textField.
			//2. The label name should not be null
		//POST-CONDITION: 
			//1. Associates this label to the Text Field and its data. 
		public StudentFormRadioButtonListener (String radioButtonlabel)
		{
			this.radioButtonLabelx_ = radioButtonlabel;
		}

	@Override
	public void actionPerformed(ActionEvent e){
	

		this.radioButtonValuex_ = e.getActionCommand();
			// TODO Auto-generated method stub
		StudentInformationForm.studentInfoFormIp.put(this.radioButtonLabelx_, this.radioButtonValuex_);
		}

	}
